#include "error.h"

#include <array>
#include <cstring>

namespace _ {



static thread_local std::array<char, 1 << 10> buffer{};

}


char *Wrap::strerror_r_(int errnum) {
    PERROR_EQ0(::strerror_r(errnum, _::buffer.data(), _::buffer.size()));
    return _::buffer.data();
}
